1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
| #include<iostream> #include<string> #include<sstream> #include<fstream> using namespace std; int main() { string str1; string str2; getline(cin, str1); getline(cin, str2); string str = str1 + "\n" + str2; std::ofstream f("D:\\answer\\answer.txt", std::ios::app); f << str << std::endl; f.close(); }
|
评论